<script>
function setFocus(){
	$('identity').focus()
}

window.addEvent('load', function(){
		$('description').mooEditable({
		actions: 'bold italic underline strikethrough | formatBlock justifyleft justifyright justifycenter justifyfull | insertunorderedlist insertorderedlist indent outdent insertHorizontalRule | undo redo removeformat | createlink unlink | urlimage | toggleview'
		});
		
		var tags = new TextboxList('tag',{
					bitsOptions:{editable:{addKeys: 188}},
//					bitsOptions:{editable:{addKeys: Event.Keys.enter}},
//					unique: true,
//					plugins: {autocomplete:{}}
					});
		
//		var tags = new TextboxList('tag', {plugins: {autocomplete:{}}});
		
//		var autocomplete = tags.plugins['autocomplete'];
//
//		autocomplete.setValues(['test','lemu']);
		
        new FormCheck('album_add', {
		display : {
			errorsLocation : 1,
			showErrors : 1,
			addClassErrorToField : 1
		}
	})
});

</script>
<style type="text/css">
			.tag { margin-bottom: 10px; }
            
            /* Setting widget width example */
            .textboxlist {width:400px;}
            
            /* Preloader for autocomplete */
            .textboxlist-loading { background: url('images/spinner.gif') no-repeat 380px center; }
            
            /* Autocomplete results styling */
            .form_friends .textboxlist-autocomplete-result { overflow: hidden; zoom: 1; }
            .form_friends .textboxlist-autocomplete-result img { float: left; padding-right: 10px; }
            
            .note { color: #666; font-size: 90%; }
            #footer { margin: 50px; text-align: center; }
			
			
	#description{
		width: 600px;
		height: 150px;
		padding: 10px;
		border: 2px solid #ddd;
	}
</style>
<form name="album_add" id="album_add" method="post" enctype="multipart/form-data" action="<?php echo site_url(array('just4u','album_save'))?>">
  <table width="0%" border="0" cellspacing="2" cellpadding="3">
    <tr>
      <th align="right">Name </th>
      <td><input name="name" type="text" id="name" class="validate['required']" /></td>
    </tr>
    <tr>
      <th align="right" valign="top">Tag </th>
      <td><input name="tag" type="text" id="tag" /></td>
    </tr>
    <tr>
      <th align="right" valign="top">Description </th>
      <td><textarea name="description" id="description" cols="45" rows="5"></textarea></td>
    </tr>
    <tr>
      <th align="right" valign="top">&nbsp;</th>
      <td align="right"><input type="reset" name="button2" id="button2" value="Reset" class="uiButtonRounded" />
        <input type="submit" name="button" id="button" value="Save" class="uiButtonRounded" /></td>
    </tr>
  </table>
</form>